package org.example.rubbish.vo;

import java.util.List;

public class PageResultProduct<T> {
    private List<T> list;
    private Long total;
    private Integer page;
    private Integer limit;
    private Integer totalPages;

    public PageResultProduct(List<T> list, Long total, Integer page, Integer limit) {
        this.list = list;
        this.total = total;
        this.page = page;
        this.limit = limit;
        this.totalPages = (int) Math.ceil((double) total / limit);
    }
}
